#include <iostream>
#include <random>
#include <sstream>
#include <iomanip>
#include <atomic>

int main()
{
    std::random_device rd; //机器随机数，效率较底

    std::mt19937_64 generator(rd()); //梅森旋转算法，伪随机数

    std::uniform_int_distribution<int> distribution(0, 255); //限定数字范围

    std::stringstream ss;
    for(int i = 0; i < 8; i++)
    {
        ss << std::setw(2) << std::setfill('0') << std::hex << distribution(generator); //转为16进制
        if(i == 3 || i == 5 || i == 7) ss << "-";
    }

    static std::atomic<int> seq(1); //序号
    size_t num = seq.fetch_add(1);
    for(int i = 7; i >= 0; i--)
    {
        ss << std::setw(2) << std::setfill('0') << std::hex << ((num >> (i*8)) & 0xff);
        if(i == 6) ss << "-";
    }

    std::cout << ss.str() <<std::endl;

    return 0;
}